#ifndef FICHIERDIAL_H
#define FICHIERDIAL_H


#include <iostream>
#include <fstream>
#include <string>
#include <SFML/Graphics.hpp>
#include "Fighter.h"
#include "Pnj.h"
#include "NameList.h"
#include "Screen.h"


using namespace std;
using namespace sf;

class FichierDial
{
    private:
        fstream fichier;
        string* text;
        Image imgScreenDial;
        Sprite screenDial;
        int numDial;
        int maxDial;
        bool pnjTalk;
        Screen* screen;
        Event event;
        Font MyFont;
        NameList* list;
        Pnj* pnj;
        Fighter* perso;


    public:
        FichierDial();
        ~FichierDial();
        int searchDial(string n, string s, string scene);
        bool isEnd();
        string readWord();
        void drawDial();
        void draw();
        string readLine();
        bool endRead();
        bool endLine();
        void setScreen(Screen* s);
        void renderDialogue(Pnj* p, Fighter* per, string scene);
        string getPnjName(string code);
        void setList(NameList* l);
};


#endif
